{include file="comm/left"}
<link rel="stylesheet" href="__STATIC__/js/pintuer.css">
<link rel="stylesheet" href="__STATIC__/js/admin.css">
<script>
    KE.show({
        id : 'content',
    });
</script>
<body>
<div class="panel admin-panel">
    <div class="panel-head"><strong><span class="ibox-title"></span> 商品详情图片</strong></div>
    <a class="btn btn-primary" style="marign-top:30px;" href="{:url('issues/adddetails')}?id={$id}"> 新增图片</a>
    <div class="body-content">

        <div class="form-group" style="overflow:hidden">
            {volist name="data" id="data"}
            <div  style='text-align: left;float:left;width:20%;overflow:hidden'>
                <ul style='float:left;overflow:hidden'>
                    <li><span class="jqzoom"><img jqimg=" " src="__STATIC__/img_issue/{$data.url}" width="100px" height="100px"></span></li>
                    <li>
                        <a class="abc" href="{:url('index/issues/deldetails')}?id={$data.id}&ids={$data.issueid}" onclick="return confirm('您确定删除此张商品详情图片吗？')"> 删除</a>
                        序号<input type="hidden" name="hidden" value="{$data['id']}">
                        <input type="text" style="border-radius:5px" size=5 class="ab" value="{$data['sort']}" >
                    </li>
                </ul>
            </div>
            {/volist}
        </div>

        <div class="form-group">
            <div class="">
                <label></label>
            </div>
            <div class="field" >
                <input type="hidden" name="hid" value="">
                <input class="button bg-main icon-check-square-o" type="button" name="sub" value="返回" onclick="javascrtpt:window.location.href='{:url('index/issues/commodity')}'" style="align:center;margin:0 auto;display:block">
            </div>
        </div>
    </div>
</div>
<script type="text/javascript">
    $('.ab').change(function () {
        var ID = $(this).val();//改变的新值
        var ids = $(this).prev().val();//图片id
        $.ajax({
            type: "POST",
            url: "{:url('index/issues/modsorts')}",
            data: "ID="+ ID +"&ids="+ ids +"",
            success: function(msg){
                alert( '修改成功' );
            }
        });
    });
</script>
</body>

